﻿@model PessModel.Rule

@{
    ViewBag.Title = "Delete";
}

<h2>Delete Rule</h2>
<div id="operate">@Html.ActionLink("Back", "Details", new {subjectID=Model.SubjectID })</div>

<fieldset class="show">
    @Html.Hidden("SubjectID",Model.SubjectID)
    <legend></legend>
    <div class="display-label">
         Name
    </div>
    <div class="display-field">
        @Html.DisplayFor(model => model.Name)
    </div>

    <div class="display-label">
         Description
    </div>
    <div class="display-field">
        @Html.DisplayFor(model => model.Description)
    </div>

    <div class="display-label">
         Score
    </div>
    <div class="display-field">
        @Html.DisplayFor(model => model.Value)
    </div>
</fieldset>
@if(Model.Scores.Count==0)
{
    using (Html.BeginForm()) {
        @Html.AntiForgeryToken()
        <h3>If the rule has been used, the rule cannot be deleted. This rule has been used @Model.Scores.Count times. </h3>
        <h3>Are you sure to delete the rule?&#8195;</h3>
        <div class="del_btn">&#8195;<input type="submit" value="Delete" /></div>
            
    }
}
